Skip to content

feat: enhancements June 2025#28

Merged
thushan merged 14 commits into
mainfrom
feature/enhancements-june-2025-1
Jul 3, 2025
Merged

feat: enhancements June 2025#28
thushan merged 14 commits into
mainfrom
feature/enhancements-june-2025-1

Conversation

@thushan
Copy link
Copy Markdown
Owner

@thushan thushan commented Jun 18, 2025

Enhancements in June

  • Adds request logging to the httpserver (can be annoying for healthchecks in podman)
  • fix missing families in the discovery
  • adds eventbus for future usage
  • some basic work around ignoring/blocking unesafe headers

@thushan thushan marked this pull request as ready for review July 3, 2025 11:55
@thushan thushan requested a review from Copilot July 3, 2025 11:55
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces a suite of enhancements for June 2025, including request‐level logging, a new generic EventBus system with tests, and improved header filtering in the Sherpa proxy.

  • Adds request_logging toggle and middleware to HTTP handlers
  • Implements EventBus[T] with full test coverage
  • Filters unsafe headers and injects proxy headers in Sherpa engine

Reviewed Changes

Copilot reviewed 43 out of 44 changed files in this pull request and generated no comments.

Show a summary per file
File Description
readme.md Updated features, config options, and usage examples
pkg/eventbus/eventbus.go (+ tests) Added lock-free EventBus implementation and tests
internal/app/handlers/server.go Introduced request‐logging middleware
internal/adapter/proxy/proxy_sherpa.go Added header filtering and proxy metadata headers
internal/logger/styled_pretty.go Extended logger interface (missing import)
internal/logger/styled_plain.go Extended logger interface (missing import)
internal/version/version.go Bumped version placeholder
Comments suppressed due to low confidence (5)

internal/version/version.go:18

  • [nitpick] The version placeholder "v0.0.x" should be updated to an actual release version or managed via build tooling.
	Version      = "v0.0.x"

internal/logger/styled_pretty.go:29

  • This method calls fmt.Sprintf and fmt.Print but the fmt package is not imported. Please add import "fmt".
func (sl *PrettyStyledLogger) InfoWithStatus(msg string, status string, args ...any) {

internal/logger/styled_plain.go:21

  • This method uses fmt.Print but the fmt package is not imported. Please add import "fmt".
func (sl *PlainStyledLogger) ResetLine() {

internal/app/handlers/server.go:60

  • configServer is undefined in this scope. It should reference the application configuration (e.g., a.Config.Server.RequestLogging).
	if configServer.RequestLogging {

internal/adapter/proxy/proxy_sherpa.go:390

  • constants.ProtocolHTTPS and constants.ProtocolHTTP are not defined or imported. Consider using literal strings "https"/"http" or import the correct package.
		protocol = constants.ProtocolHTTPS

@thushan thushan merged commit c16bd2e into main Jul 3, 2025
2 checks passed
@thushan thushan deleted the feature/enhancements-june-2025-1 branch July 3, 2025 11:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants